import {
    MAIN_FILE_CODE,
    MAIN_FILE_FILENAME_A,
    MAIN_FILE_FILENAME_B,
    MAIN_FILE_FILENAME_C,
    MAIN_FILE_FILENAME_D,
    MAIN_FILE_FILENAME_E,
    MAIN_FILE_RECTIFY_CONTENT,
    MAIN_FILE_RECTIFY_FINISHED,
    MAIN_FILE_VERSION_NAME,
    MAIN_FILE_VERSION_TIME,
    MAIN_FILE_VERSION_OPERATPR,
    MAIN_FILE_FIRST_FORM_FILENAME_A,
    MAIN_FILE_FIRST_FORM_FILENAME_B,
    MAIN_FILE_FIRST_FORM_FILENAME_C,
    MAIN_FILE_FIRST_FORM_FILENAME_D,
    MAIN_FILE_FIRST_FORM_FILENAME_E,
    MAIN_FILE_FIRST_FORM_FILENAME_F,
    MAIN_FILE_FIRST_FORM_FILENAME_G,
    MAIN_FILE_FIRST_FORM_FILENAME_H,
    MAIN_FILE_FIRST_FORM_FILENAME_I,
    MAIN_FILE_FOURTH_FORM_FILENAME_A,
    MAIN_FILE_FOURTH_FORM_FILENAME_B,
    MAIN_FILE_FOURTH_FORM_FILENAME_C,
    MAIN_FILE_FOURTH_FORM_FILENAME_D,
    MAIN_FILE_FOURTH_FORM_FILENAME_E,
    MAIN_FILE_FOURTH_FORM_FILENAME_F,
    MAIN_FILE_FOURTH_FORM_FILENAME_G,
    MAIN_FILE_FOURTH_FORM_FILENAME_H,
} from './enumConfig'
// 项目验收单表头
const accOptionColumns = [
    {
        label: '项目编码',
        prop: MAIN_FILE_CODE
    }, {
        label: '文件名称',
        prop: MAIN_FILE_FILENAME_A
    }, {
        label: '文件名称',
        prop: MAIN_FILE_FILENAME_B,
    }, {
        label: '文件名称',
        prop: MAIN_FILE_FILENAME_C,
    }, {
        label: '文件名称',
        prop: MAIN_FILE_FILENAME_D,
    }
]
// 项目接维单表头
const dimenOptionColumns = [
    {
        label: '项目编码',
        prop: MAIN_FILE_CODE
    }, {
        label: '文件名称',
        prop: MAIN_FILE_FILENAME_A
    }, {
        label: '文件名称',
        prop: MAIN_FILE_FILENAME_B,
    }, {
        label: '文件名称',
        prop: MAIN_FILE_FILENAME_C,
    }, {
        label: '文件名称',
        prop: MAIN_FILE_FILENAME_D,
    }, {
        label: '文件名称',
        prop: MAIN_FILE_FILENAME_E,
    }
]
export const columnsOption = {
    'F1': accOptionColumns,
    'F12': dimenOptionColumns
}
// 弹框内容
export const dialogInfoOption = [
    {
        label: '项目编码:',
        prop: 'prjCode'
    }, {
        label: '站址编码:',
        prop: 'siteId'
    }, {
        label: '站址名称:',
        prop: 'siteName'
    }
]
// 按钮
export const dialogBtnOption = [
    {
        label: '更新',
        click: 'updateInfo'
    }, {
        label: '查看版本记录',
        click: 'checkInfo'
    }
]

// 添加整改
export const addRectifyOption = [
    {
        label: '整改项内容',
        prop: MAIN_FILE_RECTIFY_CONTENT,
        writeEdit: true,
    }, {
        label: '是否完成整改',
        prop: MAIN_FILE_RECTIFY_FINISHED,
        edit: true
    }
]
// 版本记录
export const versionRecordOption = [
    {
        label: '文件名称',
        prop: MAIN_FILE_VERSION_NAME
    }, {
        label: '保存时间',
        prop: MAIN_FILE_VERSION_TIME
    },
    {
        label: '保存人',
        prop: MAIN_FILE_VERSION_OPERATPR
    }
]

const commonFormOptionA = [
    {
        label: '交维类别',
        prop: MAIN_FILE_FIRST_FORM_FILENAME_A
    }, {
        label: '交维分项',
        prop: MAIN_FILE_FIRST_FORM_FILENAME_B
    }, {
        label: '交维内容',
        prop: MAIN_FILE_FIRST_FORM_FILENAME_C
    }, {
        label: '交维标准',
        prop: MAIN_FILE_FIRST_FORM_FILENAME_D
    },
    {
        label: '交维方式',
        prop: MAIN_FILE_FIRST_FORM_FILENAME_E
    },
    {
        label: '系统核验结果',
        prop: MAIN_FILE_FIRST_FORM_FILENAME_F,
        edit: true
    },
    {
        label: '项目经理核验结果',
        prop: MAIN_FILE_FIRST_FORM_FILENAME_G,
        edit: true
    },
    {
        label: '维护经理核验结果',
        prop: MAIN_FILE_FIRST_FORM_FILENAME_H,
        edit: true
    },
    {
        label: '是否完成整改',
        prop: MAIN_FILE_FIRST_FORM_FILENAME_I,
        edit: true
    }
]
const commonFormOptionB = [
    {
        label: '交维类别',
        prop: MAIN_FILE_FOURTH_FORM_FILENAME_A
    }, {
        label: '交维分项',
        prop: MAIN_FILE_FOURTH_FORM_FILENAME_B,
    }, {
        label: '交维内容',
        prop: MAIN_FILE_FOURTH_FORM_FILENAME_C,
    }, {
        label: '交维标准',
        prop: MAIN_FILE_FOURTH_FORM_FILENAME_D,
    },
    {
        label: '交维材料',
        prop: MAIN_FILE_FOURTH_FORM_FILENAME_E,
    },
    {
        label: '项目经理核验结果',
        prop: MAIN_FILE_FOURTH_FORM_FILENAME_F,
        edit: true
    },
    {
        label: '维护经理核验结果',
        prop: MAIN_FILE_FOURTH_FORM_FILENAME_G,
        edit: true
    },
    {
        label: '是否完成整改',
        prop: MAIN_FILE_FOURTH_FORM_FILENAME_H,
        edit: true
    }
]
// 通用表单表头
export const commonFormOption = {
    'F1': {
        '01': commonFormOptionA,
        '04': commonFormOptionB,
    },
    'F12': {
        '01': commonFormOptionA,
        '04': commonFormOptionB,
    }
}

const CheckListA = [
    { value: '0', label: '合格' },
    { value: '1', label: '不合格' },
    { value: '2', label: '不涉及该项目' },
]
const CheckListB = [
    { value: '0', label: '合格' },
    { value: '1', label: '不合格' },
    { value: '2', label: '不涉及该项目' },
    { value: '3', label: '遗留问题' },
]
export const CheckListC = [
    { value: '0', label: '是' },
    { value: '1', label: '否' },
]
// 01
const commonCheckTypeObjA = {
    [MAIN_FILE_FIRST_FORM_FILENAME_F]: CheckListA,
    [MAIN_FILE_FIRST_FORM_FILENAME_G]: CheckListB,
    [MAIN_FILE_FIRST_FORM_FILENAME_H]: CheckListB,
    [MAIN_FILE_FIRST_FORM_FILENAME_I]: CheckListC
}
// 04
const commonCheckTypeObjB = {
    [MAIN_FILE_FOURTH_FORM_FILENAME_F]: CheckListB,
    [MAIN_FILE_FOURTH_FORM_FILENAME_G]: CheckListB,
    [MAIN_FILE_FOURTH_FORM_FILENAME_H]: CheckListC
}
export const commonCheckTypeObj = {
    'F1': {
        '01': commonCheckTypeObjA,
        '04': commonCheckTypeObjB,
    },
    'F12': {
        '01': commonCheckTypeObjA,
        '04': commonCheckTypeObjB,
    },
}


export const tabsOption = [
    {
        label: '设备设施工程质量接维单',
        name: '01'
    },
    {
        label: '设备设施运维质量接维单',
        name: '02'
    },
    {
        label: '资源资产一致性接维单',
        name: '03'
    },
    {
        label: '物业接维单',
        name: '04'
    }
]

const mergeFieldsA = [
    MAIN_FILE_FIRST_FORM_FILENAME_A, MAIN_FILE_FIRST_FORM_FILENAME_B, MAIN_FILE_FIRST_FORM_FILENAME_C
]
const mergeFieldsB = [
    MAIN_FILE_FOURTH_FORM_FILENAME_A, MAIN_FILE_FOURTH_FORM_FILENAME_B, MAIN_FILE_FOURTH_FORM_FILENAME_C
]
export const mergeFields = {
    'F1': {
        '01': mergeFieldsA,
        '04': mergeFieldsB,
    },
    'F12': {
        '01': mergeFieldsA,
        '04': mergeFieldsB,
    }
}

//  禁用字段列表
const commonDiabledPropA = [
    MAIN_FILE_FIRST_FORM_FILENAME_F,
    MAIN_FILE_FIRST_FORM_FILENAME_H,
]
const commonDiabledPropB = [
    MAIN_FILE_FOURTH_FORM_FILENAME_G
]
const commonDiabledPropC = [
    MAIN_FILE_FIRST_FORM_FILENAME_F,
    MAIN_FILE_FIRST_FORM_FILENAME_G
]
const commonDiabledPropD = [
    MAIN_FILE_FOURTH_FORM_FILENAME_F
]
export const commonDiabledProp = {
    'F1': {
        '01': commonDiabledPropA,
        '04': commonDiabledPropB,
    },
    'F12': {
        '01': commonDiabledPropC,
        '04': commonDiabledPropD,
    }
}